<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Whisper: CShiftRegister Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Whisper
   
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a>  </div>
  <div class="headertitle">
<div class="title">CShiftRegister Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="CShiftRegister" -->
<p>Implementation of a linear feedback shift register.  
 <a href="classCShiftRegister.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="shift__register_8h_source.html">shift_register.h</a>&gt;</code></p>

<p><a href="classCShiftRegister-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#a7f85d0451234c8e17f22ea59fea0d44b">CShiftRegister</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#aaafa2480f9e74975d665164272b69f61">~CShiftRegister</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#aa9c39a7cf284f8a724b90d523791112b">setParameters</a> (unsigned int pRegisterLength, unsigned int pSequenceLength, std::vector&lt; unsigned int &gt; &amp;pFeedback)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#a8136c48384cbed5f67b6d6c81877fb08">getRandomSequence</a> (bool *&amp;pSequence)</td></tr>
<tr><td colspan="2"><h2><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#ae2a914908d32d27a3d39ec82dced98fb">CShiftRegister</a> (const <a class="el" href="classCShiftRegister.html">CShiftRegister</a> &amp;)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classCShiftRegister.html">CShiftRegister</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#a60e941ce058accea04580f4d759027d7">operator=</a> (const <a class="el" href="classCShiftRegister.html">CShiftRegister</a> &amp;)</td></tr>
<tr><td colspan="2"><h2><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#a30bdf324807727e36bb0a8515f92915f">mReady</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#a8ec9e898a4ea0d55bcfb6a53fb4e1d5d">mRegisterLength</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#aaf1adff492a98c59faa6907ec7dae130">mSequenceLength</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">std::vector&lt; int &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#a4a1615b7d2b53043b8eb55f3543e4e68">mFeedback</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">std::vector&lt; bool &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classCShiftRegister.html#afac57ead40e8b20b6bceeb52737030ef">mRegister</a></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Implementation of a linear feedback shift register. </p>
<dl class="author"><dt><b>Author:</b></dt><dd>mnutzinger</dd></dl>
<p>Provides a random sequence of bits calcultated by the given parameters for register length, output length and feedback positions. </p>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a7f85d0451234c8e17f22ea59fea0d44b"></a><!-- doxytag: member="CShiftRegister::CShiftRegister" ref="a7f85d0451234c8e17f22ea59fea0d44b" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">CShiftRegister::CShiftRegister </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<a class="anchor" id="aaafa2480f9e74975d665164272b69f61"></a><!-- doxytag: member="CShiftRegister::~CShiftRegister" ref="aaafa2480f9e74975d665164272b69f61" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">CShiftRegister::~CShiftRegister </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<a class="anchor" id="ae2a914908d32d27a3d39ec82dced98fb"></a><!-- doxytag: member="CShiftRegister::CShiftRegister" ref="ae2a914908d32d27a3d39ec82dced98fb" args="(const CShiftRegister &amp;)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">CShiftRegister::CShiftRegister </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classCShiftRegister.html">CShiftRegister</a> &amp;&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a8136c48384cbed5f67b6d6c81877fb08"></a><!-- doxytag: member="CShiftRegister::getRandomSequence" ref="a8136c48384cbed5f67b6d6c81877fb08" args="(bool *&amp;pSequence)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool CShiftRegister::getRandomSequence </td>
          <td>(</td>
          <td class="paramtype">bool *&amp;&#160;</td>
          <td class="paramname"><em>pSequence</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Retrieve random sequence from lfsr. </p>
<dl class="note"><dt><b>Note:</b></dt><dd>: pSequence has to be allocated for at least mSequenceLength elements.</dd></dl>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">pSequence</td><td>reference parameter to which the random sequence is stored </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>error status </dd></dl>

</div>
</div>
<a class="anchor" id="a60e941ce058accea04580f4d759027d7"></a><!-- doxytag: member="CShiftRegister::operator=" ref="a60e941ce058accea04580f4d759027d7" args="(const CShiftRegister &amp;)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classCShiftRegister.html">CShiftRegister</a>&amp; CShiftRegister::operator= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classCShiftRegister.html">CShiftRegister</a> &amp;&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<a class="anchor" id="aa9c39a7cf284f8a724b90d523791112b"></a><!-- doxytag: member="CShiftRegister::setParameters" ref="aa9c39a7cf284f8a724b90d523791112b" args="(unsigned int pRegisterLength, unsigned int pSequenceLength, std::vector&lt; unsigned int &gt; &amp;pFeedback)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool CShiftRegister::setParameters </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>pRegisterLength</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>pSequenceLength</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::vector&lt; unsigned int &gt; &amp;&#160;</td>
          <td class="paramname"><em>pFeedback</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set parameters for the lfsr operation.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">pRegisterLength</td><td>desired length of the shift register </td></tr>
    <tr><td class="paramname">pSequenceLength</td><td>desired length of the random sequence </td></tr>
    <tr><td class="paramname">pFeedback</td><td>feedback positions </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>error status </dd></dl>

</div>
</div>
<hr/><h2>Member Data Documentation</h2>
<a class="anchor" id="a4a1615b7d2b53043b8eb55f3543e4e68"></a><!-- doxytag: member="CShiftRegister::mFeedback" ref="a4a1615b7d2b53043b8eb55f3543e4e68" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">std::vector&lt;int&gt; <a class="el" href="classCShiftRegister.html#a4a1615b7d2b53043b8eb55f3543e4e68">CShiftRegister::mFeedback</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>feedback positions </p>

</div>
</div>
<a class="anchor" id="a30bdf324807727e36bb0a8515f92915f"></a><!-- doxytag: member="CShiftRegister::mReady" ref="a30bdf324807727e36bb0a8515f92915f" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classCShiftRegister.html#a30bdf324807727e36bb0a8515f92915f">CShiftRegister::mReady</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>indicates whether the lfsr is ready for operation </p>

</div>
</div>
<a class="anchor" id="afac57ead40e8b20b6bceeb52737030ef"></a><!-- doxytag: member="CShiftRegister::mRegister" ref="afac57ead40e8b20b6bceeb52737030ef" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">std::vector&lt;bool&gt; <a class="el" href="classCShiftRegister.html#afac57ead40e8b20b6bceeb52737030ef">CShiftRegister::mRegister</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>the internal register </p>

</div>
</div>
<a class="anchor" id="a8ec9e898a4ea0d55bcfb6a53fb4e1d5d"></a><!-- doxytag: member="CShiftRegister::mRegisterLength" ref="a8ec9e898a4ea0d55bcfb6a53fb4e1d5d" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned int <a class="el" href="classCShiftRegister.html#a8ec9e898a4ea0d55bcfb6a53fb4e1d5d">CShiftRegister::mRegisterLength</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>length of the register </p>

</div>
</div>
<a class="anchor" id="aaf1adff492a98c59faa6907ec7dae130"></a><!-- doxytag: member="CShiftRegister::mSequenceLength" ref="aaf1adff492a98c59faa6907ec7dae130" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned int <a class="el" href="classCShiftRegister.html#aaf1adff492a98c59faa6907ec7dae130">CShiftRegister::mSequenceLength</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>length of the output sequence </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="shift__register_8h_source.html">shift_register.h</a></li>
<li><a class="el" href="shift__register_8cxx.html">shift_register.cxx</a></li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(10)"><span class="SelectionMark">&#160;</span>Defines</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>



<hr class="footer"/><address class="footer"><small>
Generated on Wed Jan 25 2012 22:00:45 for Whisper by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.7.5.1
</small></address>

</body>
</html>
